package com.spring.shops.model.result;

import com.spring.shops.model.entity.TzUser;
import com.spring.shops.model.vo.VipPageVo;
import lombok.Data;

@Data
public class VipResult {
    private String code="00000";
    private String msg=null;
    private Object data;
    private String version="mall4j.v230424";
    private Integer timestamp=null;
    private String sign=null;
    private boolean success=true;
    private boolean fail=true;

    public static VipResult vipUserResult(VipPageVo vipPageVo){
        VipResult vipResult = new VipResult();
        vipResult.setData(vipPageVo);
        vipResult.setFail(false);
        return vipResult;
    }
    public static VipResult infoResult(TzUser tzUser){
        VipResult vipResult = new VipResult();
        vipResult.setFail(false);
        vipResult.setData(tzUser);
        return vipResult;
    }
    public static VipResult updateResult(){
        VipResult vipResult = new VipResult();
        vipResult.setFail(false);
        vipResult.setMsg("ok");
        return vipResult;
    }

}
